package org.budo.mybatis.criteria.query;

import java.io.Serializable;
import java.util.Map;

/**
 * @author li
 */
public class CriteriaQuery implements Serializable {
    private static final long serialVersionUID = 2052134110539323592L;

    private Class<?> entityType;

    private String[] fields;

    private Map<String, Object> filter;

    public CriteriaQuery() {}

    public CriteriaQuery(Class<?> entityType, String[] fields, Map<String, Object> filter) {
        this.setEntityType(entityType);
        this.setFields(fields);
        this.setFilter(filter);
    }

    public Class<?> getEntityType() {
        return entityType;
    }

    public String[] getFields() {
        return fields;
    }

    public Map<String, Object> getFilter() {
        return filter;
    }

    public void setEntityType(Class<?> entityType) {
        this.entityType = entityType;
    }

    public void setFields(String[] fields) {
        this.fields = fields;
    }

    public void setFilter(Map<String, Object> filter) {
        this.filter = filter;
    }
}